#include <stdint.h>

#ifdef __i386__
typedef struct Context
{
    uint32_t eip;
    uint32_t esp;
    uint32_t ebp;
    uint32_t edi;
    uint32_t esi;
    uint32_t ebx;
} Context;

static inline void MakeContext(Context *context, void *stack, void *func)
{
    context->eip = (uint32_t)func;
    context->esp = (uint32_t)stack;
    context->ebp = (uint32_t)stack;
}
#else
#error "platform not support"
#endif
